package com.zzr.zzrbackend.pojo.dto.param;

import lombok.Data;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.Pattern;

@Data
public class RegisterParam {

    @NotBlank
    @Pattern(regexp = "^.{6,16}$", message = "密码不符合规范")
    public String password;

    @NotBlank
    @Pattern(regexp = "^.{6,16}$", message = "密码不符合规范")
    public String confirmPassword;

    @NotBlank
    @Pattern(regexp = "^([u4e00-\\u9fa5·]{1,10})$", message = "请输入汉字，数字或字母")
    public String userName;

    @NotBlank
    @Pattern(regexp = "^(1[3,456789])\\d{9}$", message = "电话号不符合规范")
    public String phone;

    public Integer code;
}
